home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1996-08-17 | 4.5 KB | [ TEXT/MPCC]
open in: MacOS 8.1
extracted
|
Win98
extracted
|
DOS
extracted
browse contents |
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary ).
Confidence Program Detection Match Type Support
66%
dexvert
Compact Compressed (Unix) (archive/compact)
ext
Supported
10%
dexvert
MacBinary (archive/macBinary)
fallback
Supported
1%
dexvert
Text File (text/txt)
fallback
Supported
100%
file
MacBinary II, Sat Aug 17 18:52:33 1996, modified Sat Aug 17 18:52:33 1996, creator 'MPCC', type ASCII, 3887 bytes "StubMod.c" , at 0xfaf 456 bytes resource
default (weak)
99%
file
data
default
74%
TrID
Macintosh plain text (MacBinary)
default
25%
TrID
MacBinary 2
default (weak)
100%
siegfried
fmt/1762 MacBinary (II)
default
100%
lsar
MacBinary
default
id metadata key value macFileType [ TEXT] macFileCreator [ MPCC]
hex view +--------+-------------------------+-------------------------+--------+--------+ |00000000| 00 09 53 74 75 62 4d 6f | 64 2e 63 00 00 00 00 00 |..StubMo|d.c.....| |00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000040| 00 54 45 58 54 4d 50 43 | 43 00 00 00 00 00 00 00 |.TEXTMPC|C.......| |00000050| 00 00 00 00 00 0f 2f 00 | 00 01 c8 ae 3b fd b1 ae |....../.|....;...| |00000060| 3b fd b1 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |;.......|........| |00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 19 2a 00 00 |........|.....*..| |00000080| 2f 2a 0d 09 53 74 75 62 | 4d 6f 64 2e 63 0d 09 54 |/*..Stub|Mod.c..T| |00000090| 68 69 73 20 66 69 6c 65 | 20 63 72 65 61 74 65 73 |his file| creates| |000000a0| 20 74 68 65 20 36 38 6b | 20 27 41 44 67 6d 27 20 | the 68k| 'ADgm' | |000000b0| 72 65 73 6f 75 72 63 65 | 20 74 6f 20 63 61 6c 6c |resource| to call| |000000c0| 20 79 6f 75 72 20 50 50 | 43 20 6d 6f 64 75 6c 65 | your PP|C module| |000000d0| 2e 0d 09 49 74 73 20 64 | 65 73 69 67 6e 65 64 20 |...Its d|esigned | |000000e0| 74 6f 20 62 65 20 63 6f | 6d 70 69 6c 65 64 20 61 |to be co|mpiled a| |000000f0| 73 20 61 20 63 6f 64 65 | 20 72 65 73 6f 75 72 63 |s a code| resourc| |00000100| 65 20 61 6e 64 20 74 68 | 65 6e 20 69 6e 63 6c 75 |e and th|en inclu| |00000110| 64 65 64 20 69 6e 20 79 | 6f 75 72 20 50 50 43 20 |ded in y|our PPC | |00000120| 73 68 61 72 65 64 20 6c | 69 62 61 72 79 20 70 72 |shared l|ibary pr| |00000130| 6f 6a 65 63 74 2e 0d 0d | 09 43 72 65 61 74 65 64 |oject...|.Created| |00000140| 20 62 79 20 53 74 65 76 | 65 20 5a 65 6c 6c 65 72 | by Stev|e Zeller| |00000150| 73 0d 09 36 2f 32 2f 39 | 35 09 61 65 61 20 28 41 |s..6/2/9|5.aea (A| |00000160| 6e 64 72 65 77 20 41 72 | 6d 73 74 72 6f 6e 67 29 |ndrew Ar|mstrong)| |00000170| 20 4d 6f 64 69 66 65 64 | 20 66 6f 72 20 43 6f 64 | Modifed| for Cod| |00000180| 65 57 61 72 72 69 6f 72 | 20 26 20 70 72 6f 70 65 |eWarrior| & prope| |00000190| 72 20 43 50 55 20 63 68 | 65 63 6b 69 6e 67 2e 0d |r CPU ch|ecking..| |000001a0| 2a 2f 0d 0d 23 64 65 66 | 69 6e 65 20 47 45 4e 45 |*/..#def|ine GENE| |000001b0| 52 41 54 49 4e 47 36 38 | 4b 20 31 0d 23 69 6e 63 |RATING68|K 1.#inc| |000001c0| 6c 75 64 65 20 3c 43 6f | 6e 64 69 74 69 6f 6e 61 |lude <Co|nditiona| |000001d0| 6c 4d 61 63 72 6f 73 2e | 68 3e 0d 23 69 6e 63 6c |lMacros.|h>.#incl| |000001e0| 75 64 65 20 3c 43 6f 64 | 65 46 72 61 67 6d 65 6e |ude <Cod|eFragmen| |000001f0| 74 73 2e 68 3e 0d 23 69 | 6e 63 6c 75 64 65 20 3c |ts.h>.#i|nclude <| |00000200| 4d 69 78 65 64 4d 6f 64 | 65 2e 68 3e 0d 23 69 6e |MixedMod|e.h>.#in| |00000210| 63 6c 75 64 65 20 3c 54 | 79 70 65 73 2e 68 3e 0d |clude <T|ypes.h>.| |00000220| 23 69 6e 63 6c 75 64 65 | 20 3c 4f 53 55 74 69 6c |#include| <OSUtil| |00000230| 73 2e 68 3e 0d 23 69 6e | 63 6c 75 64 65 20 3c 52 |s.h>.#in|clude <R| |00000240| 65 73 6f 75 72 63 65 73 | 2e 68 3e 0d 23 69 6e 63 |esources|.h>.#inc| |00000250| 6c 75 64 65 20 3c 4d 65 | 6d 6f 72 79 2e 68 3e 0d |lude <Me|mory.h>.| |00000260| 23 69 6e 63 6c 75 64 65 | 20 3c 41 34 53 74 75 66 |#include| <A4Stuf| |00000270| 66 2e 68 3e 0d 23 69 6e | 63 6c 75 64 65 20 3c 51 |f.h>.#in|clude <Q| |00000280| 75 69 63 6b 64 72 61 77 | 2e 68 3e 0d 23 69 6e 63 |uickdraw|.h>.#inc| |00000290| 6c 75 64 65 20 3c 4c 6f | 77 4d 65 6d 2e 68 3e 0d |lude <Lo|wMem.h>.| |000002a0| 23 69 6e 63 6c 75 64 65 | 20 3c 47 65 73 74 61 6c |#include| <Gestal| |000002b0| 74 45 71 75 2e 68 3e 0d | 0d 2f 2f 20 36 2f 32 2f |tEqu.h>.|.// 6/2/| |000002c0| 39 35 20 61 65 61 09 4e | 65 77 52 6f 75 74 69 6e |95 aea.N|ewRoutin| |000002d0| 65 44 65 73 63 72 69 70 | 74 6f 72 20 69 73 20 61 |eDescrip|tor is a| |000002e0| 6c 6c 72 65 61 64 79 20 | 64 65 66 69 6e 65 64 20 |llready |defined | |000002f0| 69 6e 20 4d 69 78 65 64 | 4d 6f 64 65 2e 68 20 61 |in Mixed|Mode.h a| |00000300| 73 20 36 38 6b 20 63 6f | 64 65 2e 0d 2f 2f 20 42 |s 68k co|de..// B| |00000310| 79 20 64 65 63 6c 61 72 | 69 6e 67 20 4d 79 4e 65 |y declar|ing MyNe| |00000320| 77 52 6f 75 74 69 6e 65 | 44 65 73 63 72 69 70 74 |wRoutine|Descript| |00000330| 6f 72 2c 20 49 20 61 6d | 20 61 62 6c 65 20 74 6f |or, I am| able to| |00000340| 20 63 61 6c 6c 20 74 68 | 65 20 4d 69 78 65 64 4d | call th|e MixedM| |00000350| 6f 64 65 4d 61 6e 61 67 | 65 72 20 74 72 61 70 2e |odeManag|er trap.| |00000360| 0d 65 78 74 65 72 6e 20 | 70 61 73 63 61 6c 20 55 |.extern |pascal U| |00000370| 6e 69 76 65 72 73 61 6c | 50 72 6f 63 50 74 72 20 |niversal|ProcPtr | |00000380| 4d 79 4e 65 77 52 6f 75 | 74 69 6e 65 44 65 73 63 |MyNewRou|tineDesc| |00000390| 72 69 70 74 6f 72 28 50 | 72 6f 63 50 74 72 20 74 |riptor(P|rocPtr t| |000003a0| 68 65 50 72 6f 63 2c 20 | 50 72 6f 63 49 6e 66 6f |heProc, |ProcInfo| |000003b0| 54 79 70 65 20 74 68 65 | 50 72 6f 63 49 6e 66 6f |Type the|ProcInfo| |000003c0| 2c 20 49 53 41 54 79 70 | 65 20 74 68 65 49 53 41 |, ISATyp|e theISA| |000003d0| 29 20 3d 20 7b 30 78 37 | 30 30 30 2c 20 30 78 41 |) = {0x7|000, 0xA| |000003e0| 41 35 39 7d 3b 0d 0d 23 | 69 6e 63 6c 75 64 65 20 |A59};..#|include | |000003f0| 22 47 72 61 70 68 69 63 | 73 4d 6f 64 75 6c 65 5f |"Graphic|sModule_| |00000400| 54 79 70 65 73 2e 68 22 | 0d 0d 23 64 65 66 69 6e |Types.h"|..#defin| |00000410| 65 20 6b 46 72 61 67 6d | 65 6e 74 4e 61 6d 65 09 |e kFragm|entName.| |00000420| 22 5c 70 6d 61 69 6e 22 | 0d 23 64 65 66 69 6e 65 |"\pmain"|.#define| |00000430| 20 6b 45 6e 74 72 79 50 | 6f 69 6e 74 4e 61 6d 65 | kEntryP|ointName| |00000440| 09 22 5c 70 6d 61 69 6e | 22 0d 0d 43 6f 6e 6e 65 |."\pmain|"..Conne| |00000450| 63 74 69 6f 6e 49 44 20 | 74 68 65 43 6f 6e 6e 65 |ctionID |theConne| |00000460| 63 74 69 6f 6e 49 44 3b | 0d 50 74 72 20 74 68 65 |ctionID;|.Ptr the| |00000470| 45 6e 74 72 79 50 6f 69 | 6e 74 3b 0d 74 79 70 65 |EntryPoi|nt;.type| |00000480| 64 65 66 20 70 61 73 63 | 61 6c 20 4f 53 45 72 72 |def pasc|al OSErr| |00000490| 20 28 2a 4d 6f 64 75 6c | 65 50 72 6f 63 50 74 72 | (*Modul|eProcPtr| |000004a0| 29 28 48 61 6e 64 6c 65 | 2a 20 73 74 6f 72 61 67 |)(Handle|* storag| |000004b0| 65 2c 20 52 67 6e 48 61 | 6e 64 6c 65 20 72 67 6e |e, RgnHa|ndle rgn| |000004c0| 2c 20 73 68 6f 72 74 20 | 6d 73 67 2c 20 47 4d 50 |, short |msg, GMP| |000004d0| 61 72 61 6d 42 6c 6f 63 | 6b 50 74 72 20 70 61 72 |aramBloc|kPtr par| |000004e0| 61 6d 73 29 3b 0d 0d 4d | 6f 64 75 6c 65 50 72 6f |ams);..M|odulePro| |000004f0| 63 50 74 72 20 74 68 65 | 44 65 73 63 72 69 70 74 |cPtr the|Descript| |00000500| 6f 72 20 3d 20 30 6c 3b | 0d 0d 65 6e 75 6d 20 7b |or = 0l;|..enum {| |00000510| 0d 09 65 4d 6f 64 75 6c | 65 44 69 73 70 61 74 63 |..eModul|eDispatc| |00000520| 68 53 65 6c 65 63 74 6f | 72 20 3d 20 6b 50 61 73 |hSelecto|r = kPas| |00000530| 63 61 6c 53 74 61 63 6b | 42 61 73 65 64 0d 09 09 |calStack|Based...| |00000540| 20 7c 20 52 45 53 55 4c | 54 5f 53 49 5a 45 28 53 | | RESUL|T_SIZE(S| |00000550| 49 5a 45 5f 43 4f 44 45 | 28 73 69 7a 65 6f 66 28 |IZE_CODE|(sizeof(| |00000560| 4f 53 45 72 72 29 29 29 | 0d 09 09 20 7c 20 53 54 |OSErr)))|... | ST| |00000570| 41 43 4b 5f 52 4f 55 54 | 49 4e 45 5f 50 41 52 41 |ACK_ROUT|INE_PARA| |00000580| 4d 45 54 45 52 28 31 2c | 20 53 49 5a 45 5f 43 4f |METER(1,| SIZE_CO| |00000590| 44 45 28 73 69 7a 65 6f | 66 28 20 48 61 6e 64 6c |DE(sizeo|f( Handl| |000005a0| 65 2a 29 29 29 0d 09 09 | 20 7c 20 53 54 41 43 4b |e*)))...| | STACK| |000005b0| 5f 52 4f 55 54 49 4e 45 | 5f 50 41 52 41 4d 45 54 |_ROUTINE|_PARAMET| |000005c0| 45 52 28 32 2c 20 53 49 | 5a 45 5f 43 4f 44 45 28 |ER(2, SI|ZE_CODE(| |000005d0| 73 69 7a 65 6f 66 28 20 | 52 67 6e 48 61 6e 64 6c |sizeof( |RgnHandl| |000005e0| 65 29 29 29 0d 09 09 20 | 7c 20 53 54 41 43 4b 5f |e)))... || STACK_| |000005f0| 52 4f 55 54 49 4e 45 5f | 50 41 52 41 4d 45 54 45 |ROUTINE_|PARAMETE| |00000600| 52 28 33 2c 20 53 49 5a | 45 5f 43 4f 44 45 28 73 |R(3, SIZ|E_CODE(s| |00000610| 69 7a 65 6f 66 28 73 68 | 6f 72 74 29 29 29 0d 09 |izeof(sh|ort)))..| |00000620| 09 20 7c 20 53 54 41 43 | 4b 5f 52 4f 55 54 49 4e |. | STAC|K_ROUTIN| |00000630| 45 5f 50 41 52 41 4d 45 | 54 45 52 28 34 2c 20 53 |E_PARAME|TER(4, S| |00000640| 49 5a 45 5f 43 4f 44 45 | 28 73 69 7a 65 6f 66 28 |IZE_CODE|(sizeof(| |00000650| 20 47 4d 50 61 72 61 6d | 42 6c 6f 63 6b 2a 29 29 | GMParam|Block*))| |00000660| 29 0d 7d 3b 0d 0d 0d 73 | 74 61 74 69 63 20 4f 53 |).};...s|tatic OS| |00000670| 45 72 72 20 4c 6f 63 61 | 74 65 46 69 6c 65 28 73 |Err Loca|teFile(s| |00000680| 68 6f 72 74 20 72 65 66 | 4e 75 6d 2c 20 46 53 53 |hort ref|Num, FSS| |00000690| 70 65 63 2a 20 6c 6f 63 | 61 74 69 6f 6e 2c 20 6c |pec* loc|ation, l| |000006a0| 6f 6e 67 2a 20 66 69 6c | 65 4c 65 6e 29 0d 7b 0d |ong* fil|eLen).{.| |000006b0| 09 46 43 42 50 42 52 65 | 63 20 66 63 62 50 42 3b |.FCBPBRe|c fcbPB;| |000006c0| 0d 09 4f 53 45 72 72 20 | 72 65 73 75 6c 74 3b 0d |..OSErr |result;.| |000006d0| 0d 09 66 63 62 50 42 2e | 69 6f 4e 61 6d 65 50 74 |..fcbPB.|ioNamePt| |000006e0| 72 20 3d 20 28 53 74 72 | 69 6e 67 50 74 72 29 6c |r = (Str|ingPtr)l| |000006f0| 6f 63 61 74 69 6f 6e 2d | 3e 6e 61 6d 65 3b 0d 09 |ocation-|>name;..| |00000700| 66 63 62 50 42 2e 69 6f | 43 6f 6d 70 6c 65 74 69 |fcbPB.io|Completi| |00000710| 6f 6e 20 3d 20 6e 69 6c | 3b 0d 09 66 63 62 50 42 |on = nil|;..fcbPB| |00000720| 2e 69 6f 46 43 42 49 6e | 64 78 20 3d 20 30 3b 0d |.ioFCBIn|dx = 0;.| |00000730| 09 66 63 62 50 42 2e 69 | 6f 52 65 66 4e 75 6d 20 |.fcbPB.i|oRefNum | |00000740| 3d 20 72 65 66 4e 75 6d | 3b 0d 09 72 65 73 75 6c |= refNum|;..resul| |00000750| 74 20 3d 20 50 42 47 65 | 74 46 43 42 49 6e 66 6f |t = PBGe|tFCBInfo| |00000760| 28 26 66 63 62 50 42 2c | 20 66 61 6c 73 65 29 3b |(&fcbPB,| false);| |00000770| 0d 09 69 66 20 28 72 65 | 73 75 6c 74 20 3d 3d 20 |..if (re|sult == | |00000780| 6e 6f 45 72 72 29 20 7b | 0d 09 09 6c 6f 63 61 74 |noErr) {|...locat| |00000790| 69 6f 6e 2d 3e 76 52 65 | 66 4e 75 6d 20 3d 20 66 |ion->vRe|fNum = f| |000007a0| 63 62 50 42 2e 69 6f 46 | 43 42 56 52 65 66 4e 75 |cbPB.ioF|CBVRefNu| |000007b0| 6d 3b 0d 09 09 6c 6f 63 | 61 74 69 6f 6e 2d 3e 70 |m;...loc|ation->p| |000007c0| 61 72 49 44 20 3d 20 66 | 63 62 50 42 2e 69 6f 46 |arID = f|cbPB.ioF| |000007d0| 43 42 50 61 72 49 44 3b | 0d 09 09 2a 66 69 6c 65 |CBParID;|...*file| |000007e0| 4c 65 6e 20 3d 20 66 63 | 62 50 42 2e 69 6f 46 43 |Len = fc|bPB.ioFC| |000007f0| 42 50 4c 65 6e 3b 0d 09 | 7d 0d 0d 09 72 65 74 75 |BPLen;..|}...retu| |00000800| 72 6e 20 72 65 73 75 6c | 74 3b 0d 7d 0d 0d 70 61 |rn resul|t;.}..pa| |00000810| 73 63 61 6c 20 4f 53 45 | 72 72 20 6d 61 69 6e 28 |scal OSE|rr main(| |00000820| 48 61 6e 64 6c 65 2a 20 | 73 74 6f 72 61 67 65 2c |Handle* |storage,| |00000830| 20 52 67 6e 48 61 6e 64 | 6c 65 20 72 67 6e 2c 20 | RgnHand|le rgn, | |00000840| 73 68 6f 72 74 20 6d 73 | 67 2c 20 47 4d 50 61 72 |short ms|g, GMPar| |00000850| 61 6d 42 6c 6f 63 6b 50 | 74 72 20 70 61 72 61 6d |amBlockP|tr param| |00000860| 73 29 0d 7b 0d 09 4f 53 | 45 72 72 20 65 72 72 20 |s).{..OS|Err err | |00000870| 3d 20 6e 6f 45 72 72 3b | 0d 09 6c 6f 6e 67 09 6e |= noErr;|..long.n| |00000880| 61 74 69 76 65 43 50 55 | 74 79 70 65 3b 0d 09 6c |ativeCPU|type;..l| |00000890| 6f 6e 67 09 6f 6c 64 41 | 34 3b 0d 09 0d 09 6f 6c |ong.oldA|4;....ol| |000008a0| 64 41 34 20 3d 20 53 65 | 74 43 75 72 72 65 6e 74 |dA4 = Se|tCurrent| |000008b0| 41 34 28 29 3b 0d 0d 09 | 2f 2f 20 36 2f 32 2f 39 |A4();...|// 6/2/9| |000008c0| 35 20 61 65 61 20 57 65 | 72 65 20 67 6f 69 6e 67 |5 aea We|re going| |000008d0| 20 74 6f 20 61 73 73 75 | 6d 65 20 74 68 61 74 20 | to assu|me that | |000008e0| 41 70 70 6c 65 20 77 69 | 6c 6c 20 6f 6e 6c 79 20 |Apple wi|ll only | |000008f0| 70 72 6f 64 75 63 65 20 | 50 50 43 20 70 72 6f 63 |produce |PPC proc| |00000900| 65 73 73 6f 72 73 20 66 | 6f 72 20 61 77 68 69 6c |essors f|or awhil| |00000910| 65 2e 0d 09 2f 2f 20 73 | 6f 20 69 6e 73 74 65 61 |e...// s|o instea| |00000920| 64 20 6f 66 20 63 68 65 | 6b 63 69 6e 67 20 66 6f |d of che|kcing fo| |00000930| 72 20 74 68 65 20 63 6f | 64 65 20 66 72 61 67 6d |r the co|de fragm| |00000940| 65 6e 74 20 6d 61 6e 61 | 67 65 72 20 28 77 68 69 |ent mana|ger (whi| |00000950| 63 68 20 63 61 6e 20 65 | 78 69 73 74 20 6f 6e 20 |ch can e|xist on | |00000960| 36 38 6b 20 6d 61 63 68 | 69 6e 65 73 29 0d 09 2f |68k mach|ines)../| |00000970| 2f 20 77 65 20 77 69 6c | 6c 20 73 69 6d 70 6c 79 |/ we wil|l simply| |00000980| 20 6c 6f 6f 6b 20 66 6f | 72 20 61 6e 79 74 68 69 | look fo|r anythi| |00000990| 6e 67 20 61 66 74 65 72 | 20 67 65 73 74 61 6c 74 |ng after| gestalt| |000009a0| 43 50 55 36 30 31 0d 09 | 65 72 72 20 3d 20 47 65 |CPU601..|err = Ge| |000009b0| 73 74 61 6c 74 28 27 63 | 70 75 74 27 2c 20 26 6e |stalt('c|put', &n| |000009c0| 61 74 69 76 65 43 50 55 | 74 79 70 65 29 3b 0d 09 |ativeCPU|type);..| |000009d0| 69 66 20 28 28 65 72 72 | 20 21 3d 20 6e 6f 45 72 |if ((err| != noEr| |000009e0| 72 29 20 7c 7c 20 28 6e | 61 74 69 76 65 43 50 55 |r) || (n|ativeCPU| |000009f0| 74 79 70 65 20 3c 20 67 | 65 73 74 61 6c 74 43 50 |type < g|estaltCP| |00000a00| 55 36 30 31 29 29 0d 09 | 7b 0d 09 09 48 61 6e 64 |U601))..|{...Hand| |00000a10| 6c 65 20 65 72 72 6f 72 | 48 61 6e 64 6c 65 3b 0d |le error|Handle;.| |00000a20| 09 09 0d 09 09 65 72 72 | 6f 72 48 61 6e 64 6c 65 |.....err|orHandle| |00000a30| 20 3d 20 47 65 74 31 52 | 65 73 6f 75 72 63 65 28 | = Get1R|esource(| |00000a40| 27 53 54 52 20 27 2c 20 | 31 35 30 29 3b 0d 09 09 |'STR ', |150);...| |00000a50| 0d 09 09 69 66 20 28 21 | 65 72 72 6f 72 48 61 6e |...if (!|errorHan| |00000a60| 64 6c 65 29 0d 09 09 09 | 42 6c 6f 63 6b 4d 6f 76 |dle)....|BlockMov| |00000a70| 65 28 22 5c 70 53 6f 72 | 72 79 2c 20 74 68 69 73 |e("\pSor|ry, this| |00000a80| 20 6d 6f 64 75 6c 65 20 | 6f 6e 6c 79 20 72 75 6e | module |only run| |00000a90| 73 20 6f 6e 20 61 20 50 | 6f 77 65 72 4d 61 63 69 |s on a P|owerMaci| |00000aa0| 6e 74 6f 73 68 2e 22 2c | 20 70 61 72 61 6d 73 2d |ntosh.",| params-| |00000ab0| 3e 65 72 72 6f 72 4d 65 | 73 73 61 67 65 2c 20 32 |>errorMe|ssage, 2| |00000ac0| 35 35 29 3b 0d 09 09 65 | 6c 73 65 0d 09 09 7b 0d |55);...e|lse...{.| |00000ad0| 09 09 09 48 4c 6f 63 6b | 28 65 72 72 6f 72 48 61 |...HLock|(errorHa| |00000ae0| 6e 64 6c 65 29 3b 0d 09 | 09 09 42 6c 6f 63 6b 4d |ndle);..|..BlockM| |00000af0| 6f 76 65 28 2a 65 72 72 | 6f 72 48 61 6e 64 6c 65 |ove(*err|orHandle| |00000b00| 2c 20 70 61 72 61 6d 73 | 2d 3e 65 72 72 6f 72 4d |, params|->errorM| |00000b10| 65 73 73 61 67 65 2c 20 | 32 35 35 29 3b 0d 09 09 |essage, |255);...| |00000b20| 09 52 65 6c 65 61 73 65 | 52 65 73 6f 75 72 63 65 |.Release|Resource| |00000b30| 28 65 72 72 6f 72 48 61 | 6e 64 6c 65 29 3b 0d 09 |(errorHa|ndle);..| |00000b40| 09 7d 0d 0d 09 09 45 78 | 69 74 43 6f 64 65 52 65 |.}....Ex|itCodeRe| |00000b50| 73 6f 75 72 63 65 28 29 | 3b 0d 09 09 72 65 74 75 |source()|;...retu| |00000b60| 72 6e 20 2d 31 3b 09 0d | 09 7d 0d 0d 09 2f 2f 20 |rn -1;..|.}...// | |00000b70| 6f 70 65 6e 20 74 68 65 | 20 66 72 61 67 6d 65 6e |open the| fragmen| |00000b80| 74 0d 09 2f 2f 69 66 20 | 28 6d 73 67 20 3d 3d 20 |t..//if |(msg == | |00000b90| 49 6e 69 74 69 61 6c 69 | 7a 65 29 0d 09 0d 09 2f |Initiali|ze)..../| |00000ba0| 2f 20 4d 44 43 20 43 6f | 6e 74 72 6f 6c 20 70 61 |/ MDC Co|ntrol pa| |00000bb0| 6e 65 6c 20 61 70 70 61 | 72 65 6e 74 6c 79 20 64 |nel appa|rently d| |00000bc0| 6f 65 73 20 6e 6f 74 20 | 67 65 74 20 61 6e 20 49 |oes not |get an I| |00000bd0| 6e 69 74 69 61 6c 69 7a | 65 20 6d 65 73 73 61 67 |nitializ|e messag| |00000be0| 65 20 77 68 65 6e 20 69 | 74 20 69 73 0d 09 2f 2f |e when i|t is..//| |00000bf0| 20 6f 70 65 6e 65 64 2c | 20 73 6f 20 62 75 74 74 | opened,| so butt| |00000c00| 6f 6e 20 70 72 65 73 73 | 65 73 20 64 6f 20 6e 6f |on press|es do no| |00000c10| 74 20 77 6f 72 6b 2e 20 | 20 49 6e 73 74 65 61 64 |t work. | Instead| |00000c20| 2c 20 77 65 20 63 68 65 | 63 6b 20 69 66 20 74 68 |, we che|ck if th| |00000c30| 65 20 64 65 73 63 72 69 | 70 74 6f 72 20 68 61 73 |e descri|ptor has| |00000c40| 0d 09 2f 2f 20 62 65 65 | 6e 20 73 65 74 2e 0d 0d |..// bee|n set...| |00000c50| 09 69 66 20 28 20 74 68 | 65 44 65 73 63 72 69 70 |.if ( th|eDescrip| |00000c60| 74 6f 72 20 3d 3d 20 28 | 76 6f 69 64 2a 29 4e 55 |tor == (|void*)NU| |00000c70| 4c 4c 20 26 26 20 6d 73 | 67 20 21 3d 20 43 6c 6f |LL && ms|g != Clo| |00000c80| 73 65 20 29 20 7b 0d 09 | 09 50 74 72 20 65 78 70 |se ) {..|.Ptr exp| |00000c90| 6f 72 74 65 64 45 6e 74 | 72 79 50 6f 69 6e 74 3b |ortedEnt|ryPoint;| |00000ca0| 0d 09 09 53 79 6d 43 6c | 61 73 73 20 74 68 65 43 |...SymCl|ass theC| |00000cb0| 6c 61 73 73 3b 0d 09 09 | 46 53 53 70 65 63 20 74 |lass;...|FSSpec t| |00000cc0| 68 69 73 53 70 65 63 3b | 0d 09 09 6c 6f 6e 67 20 |hisSpec;|...long | |00000cd0| 74 68 69 73 4c 65 6e 3b | 0d 0d 09 09 4c 6f 63 61 |thisLen;|....Loca| |00000ce0| 74 65 46 69 6c 65 28 4c | 4d 47 65 74 43 75 72 4d |teFile(L|MGetCurM| |00000cf0| 61 70 28 29 2c 20 26 74 | 68 69 73 53 70 65 63 2c |ap(), &t|hisSpec,| |00000d00| 20 26 74 68 69 73 4c 65 | 6e 29 3b 0d 09 09 65 72 | &thisLe|n);...er| |00000d10| 72 20 3d 20 47 65 74 44 | 69 73 6b 46 72 61 67 6d |r = GetD|iskFragm| |00000d20| 65 6e 74 28 26 74 68 69 | 73 53 70 65 63 2c 20 30 |ent(&thi|sSpec, 0| |00000d30| 2c 20 6b 57 68 6f 6c 65 | 46 6f 72 6b 2c 20 6b 46 |, kWhole|Fork, kF| |00000d40| 72 61 67 6d 65 6e 74 4e | 61 6d 65 2c 20 6b 4c 6f |ragmentN|ame, kLo| |00000d50| 61 64 4e 65 77 43 6f 70 | 79 2c 20 26 74 68 65 43 |adNewCop|y, &theC| |00000d60| 6f 6e 6e 65 63 74 69 6f | 6e 49 44 2c 20 28 50 74 |onnectio|nID, (Pt| |00000d70| 72 2a 29 20 26 65 78 70 | 6f 72 74 65 64 45 6e 74 |r*) &exp|ortedEnt| |00000d80| 72 79 50 6f 69 6e 74 2c | 20 70 61 72 61 6d 73 2d |ryPoint,| params-| |00000d90| 3e 65 72 72 6f 72 4d 65 | 73 73 61 67 65 29 3b 0d |>errorMe|ssage);.| |00000da0| 0d 09 09 69 66 20 28 65 | 72 72 20 3d 3d 20 6e 6f |...if (e|rr == no| |00000db0| 45 72 72 29 0d 09 09 09 | 65 72 72 20 3d 20 46 69 |Err)....|err = Fi| |00000dc0| 6e 64 53 79 6d 62 6f 6c | 28 74 68 65 43 6f 6e 6e |ndSymbol|(theConn| |00000dd0| 65 63 74 69 6f 6e 49 44 | 2c 20 6b 45 6e 74 72 79 |ectionID|, kEntry| |00000de0| 50 6f 69 6e 74 4e 61 6d | 65 2c 20 26 74 68 65 45 |PointNam|e, &theE| |00000df0| 6e 74 72 79 50 6f 69 6e | 74 2c 20 26 74 68 65 43 |ntryPoin|t, &theC| |00000e00| 6c 61 73 73 29 3b 0d 09 | 0d 09 09 69 66 20 28 65 |lass);..|...if (e| |00000e10| 72 72 20 3d 3d 20 6e 6f | 45 72 72 29 0d 09 09 09 |rr == no|Err)....| |00000e20| 74 68 65 44 65 73 63 72 | 69 70 74 6f 72 20 3d 20 |theDescr|iptor = | |00000e30| 28 4d 6f 64 75 6c 65 50 | 72 6f 63 50 74 72 29 20 |(ModuleP|rocPtr) | |00000e40| 4d 79 4e 65 77 52 6f 75 | 74 69 6e 65 44 65 73 63 |MyNewRou|tineDesc| |00000e50| 72 69 70 74 6f 72 28 28 | 50 72 6f 63 50 74 72 29 |riptor((|ProcPtr)| |00000e60| 20 74 68 65 45 6e 74 72 | 79 50 6f 69 6e 74 2c 20 | theEntr|yPoint, | |00000e70| 65 4d 6f 64 75 6c 65 44 | 69 73 70 61 74 63 68 53 |eModuleD|ispatchS| |00000e80| 65 6c 65 63 74 6f 72 2c | 20 6b 50 6f 77 65 72 50 |elector,| kPowerP| |00000e90| 43 49 53 41 29 3b 0d 09 | 7d 0d 09 0d 09 69 66 20 |CISA);..|}....if | |00000ea0| 28 74 68 65 44 65 73 63 | 72 69 70 74 6f 72 20 26 |(theDesc|riptor &| |00000eb0| 26 20 28 65 72 72 20 3d | 3d 20 6e 6f 45 72 72 29 |& (err =|= noErr)| |00000ec0| 29 20 7b 0d 09 09 65 72 | 72 20 3d 20 28 2a 74 68 |) {...er|r = (*th| |00000ed0| 65 44 65 73 63 72 69 70 | 74 6f 72 29 28 73 74 6f |eDescrip|tor)(sto| |00000ee0| 72 61 67 65 2c 20 72 67 | 6e 2c 20 6d 73 67 2c 20 |rage, rg|n, msg, | |00000ef0| 70 61 72 61 6d 73 29 3b | 0d 09 7d 0d 0d 09 69 66 |params);|..}...if| |00000f00| 20 28 6d 73 67 20 3d 3d | 20 43 6c 6f 73 65 20 7c | (msg ==| Close || |00000f10| 7c 20 20 65 72 72 20 21 | 3d 20 6e 6f 45 72 72 29 || err !|= noErr)| |00000f20| 20 7b 0d 09 09 44 69 73 | 70 6f 73 65 52 6f 75 74 | {...Dis|poseRout| |00000f30| 69 6e 65 44 65 73 63 72 | 69 70 74 6f 72 28 28 55 |ineDescr|iptor((U| |00000f40| 6e 69 76 65 72 73 61 6c | 50 72 6f 63 50 74 72 29 |niversal|ProcPtr)| |00000f50| 20 74 68 65 44 65 73 63 | 72 69 70 74 6f 72 29 3b | theDesc|riptor);| |00000f60| 0d 09 09 43 6c 6f 73 65 | 43 6f 6e 6e 65 63 74 69 |...Close|Connecti| |00000f70| 6f 6e 28 26 74 68 65 43 | 6f 6e 6e 65 63 74 69 6f |on(&theC|onnectio| |00000f80| 6e 49 44 29 3b 0d 0d 09 | 7d 0d 0d 09 45 78 69 74 |nID);...|}...Exit| |00000f90| 43 6f 64 65 52 65 73 6f | 75 72 63 65 28 29 3b 0d |CodeReso|urce();.| |00000fa0| 09 72 65 74 75 72 6e 20 | 65 72 72 3b 0d 7d 0d 00 |.return |err;.}..| |00000fb0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000fc0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000fd0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000fe0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000ff0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00001000| 00 00 01 00 00 00 01 76 | 00 00 00 76 00 00 00 52 |.......v|...v...R| |00001010| 96 01 67 16 51 12 48 68 | 00 5a 59 5b 58 33 50 01 |..g.Q.Hh|.ZY[X3P.| |00001020| 08 32 6d 5a 5b 32 01 00 | e0 6d 96 b0 01 20 4b 11 |.2mZ[2..|.m... K.| |00001030| 09 53 74 75 62 4d 6f 64 | 2e 63 02 00 00 00 50 61 |.StubMod|.c....Pa| |00001040| 72 74 53 49 54 21 00 00 | 00 00 00 00 00 00 00 00 |rtSIT!..|........| |00001050| 00 00 50 61 72 74 53 49 | 54 21 00 00 00 00 00 00 |..PartSI|T!......| |00001060| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00001070| 00 00 ae 65 03 b3 00 00 | 00 00 00 00 01 c8 6c 02 |...e....|......l.| |00001080| 78 ff 11 c4 35 98 99 02 | 62 6f 6f 74 7d b3 02 a8 |x...5...|boot}...| |00001090| 1f 28 5f 8d b0 60 01 a9 | 92 d9 6c b0 05 3f 07 a9 |.(_..`..|..l..?..| |000010a0| 9a 3f 05 a9 98 11 c6 35 | 8d 73 02 18 f0 ff e6 2b |.?.....5|.s.....+| |000010b0| 4b 60 86 01 04 00 50 01 | 01 72 8a 26 01 01 f2 60 |K`....P.|.r.&...`| |000010c0| 7d 56 5a 4d 4c c6 c5 68 | 71 a6 12 20 4c a0 23 55 |}VZML..h|q.. L.#U| |000010d0| bb 8d 14 28 6e ff fc 4e | 5e 4e 75 15 4e 56 00 00 |...(n..N|^Nu.NV..| |000010e0| 2f 0c 28 6e 00 0c 60 55 | 56 5a 4d 4c 75 38 39 63 |/.(n..`U|VZMLu89c| |000010f0| 11 ff ce 5c 9b 70 54 8c | 4d 32 01 00 70 26 01 30 |...\.pT.|M2..p&.0| |00001100| 00 00 00 1e 00 29 00 03 | 02 70 02 3a 00 29 00 03 |.....)..|.p.:.)..| |00001110| 02 70 02 3a 00 00 00 00 | 00 00 00 00 00 00 00 00 |.p.:....|........| |00001120| 00 00 00 00 00 48 00 09 | 4d 6f 6e 61 63 6f 00 00 |.....H..|Monaco..| |00001130| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00001140| 00 00 00 00 00 00 00 00 | 00 03 00 04 00 58 00 03 |........|.....X..| |00001150| 01 cd 02 62 00 58 00 03 | 01 cd 02 62 ae 3b c5 b2 |...b.X..|...b.;..| |00001160| 00 00 0b fb 00 00 0b fb | 00 00 0b 02 01 00 00 00 |........|........| |00001170| 00 04 00 01 00 01 00 00 | 01 00 00 00 01 76 00 00 |........|.....v..| |00001180| 00 76 00 00 00 52 01 2d | b1 f8 18 9c 00 00 00 1c |.v...R.-|........| |00001190| 00 52 00 01 4d 50 53 52 | 00 01 00 12 4d 57 42 42 |.R..MPSR|....MWBB| |000011a0| 00 00 00 2a 03 f0 ff ff | 00 00 00 00 00 00 00 00 |...*....|........| |000011b0| 03 ed ff ff 00 00 00 22 | 00 00 00 00 03 f0 ff ff |......."|........| |000011c0| 00 00 00 6e 00 00 00 00 | 00 00 00 00 00 00 00 00 |...n....|........| |000011d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000011e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000011f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| +--------+-------------------------+-------------------------+--------+--------+